package com.zyl.blog.rbac.config;

import com.zyl.blog.common.handler.DesensitizationHandler;
import com.zyl.blog.rbac.advice.DesensitizeAop;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * 脱敏配置类
 * 注册脱敏相关的Bean
 * @version v1.0
 * @ProjectName: Personal_Blog_Server
 * @Package: com.zyl.blog.common.config
 * @ClassName: DesensitizeConfig
 * @Author FinalFantasy
 * @Date 2025/9/8-10:21
 */
@Configuration
public class DesensitizeConfig {

    @Bean
    public DesensitizationHandler desensitizationHandler() {
        return new DesensitizationHandler();
    }

    @Bean
    public DesensitizeAop desensitizeAop(DesensitizationHandler desensitizationHandler) {
        return new DesensitizeAop(desensitizationHandler);
    }
}

